ActiveReports 19 .NET Edition
MESCIUS.ActiveReports.Core.Rdl Assembly / GrapeCity.ActiveReports.PageReportModel.Validation Namespace / ValidationUtils Class / Validate Method / Validate<T>(T) Method
A value to validate.
Example

In This Topic
    Validate<T>(T) Method
    In This Topic
    Validates a value to make sure it is valid enum value.
    Syntax
    'Declaration
     
    Public Overloads Shared Function Validate(Of T As Enum)( _
       ByVal value As T _
    ) As T
    public static T Validate<T>( 
       T value
    )
    where T: Enum

    Parameters

    value
    A value to validate.

    Type Parameters

    T
    Exceptions
    ExceptionDescription
    Throws if the value is not valid enum of Enum type.
    Example
    OrderByCondition value = OrderByCondition.Value;
    ValidationUtils.Validate(value);
    See Also